Various electronic devices are capable of forming connections with other electronic devices to act as peripherals or to otherwise transfer information, or power (such as in the case of charging batteries). The port to which an electronic device connects to another electronic device may be a common port where the common port is multifunctional and may be used for various purposes. For example, the port may be used to charge the device, but may also be used for transmitting or receiving information. Therefore, an electronic device having such a common port needs to be capable of distinguishing what type of device is being connected, or is already connected, at the common port, so that internal switching may be applied if needed to operate the connected device, or to facilitate proper operation between the electronic device and the connected device.
The determination of a connected device type may be accomplished by using a circuit such as a comparator that checks a voltage level on a connector pin of a connector port and compares that voltage to a reference voltage. The reference voltage may be, for example, the electronic device supply voltage. The voltage check may be viewed as either checking a connector port pin of the electronic device itself, after being placed in contact with, and therefore electrically connected to, an external device connector port, or may be viewed as checking an output pin of the external connected device, because the external device, via a suitable output connector, is in electrical contact with the electronic device connector port, but is not yet connected to any other electronic device internal circuitry. As would be understood by one of ordinary skill, the connector that is the “input” or “output” is relative to the specific function the devices will be performing with respect to each other.
In some cases the voltage that must be detected on the connector pin exceeds the reference voltage, which may be the supply voltage, and this may cause accuracy concerns for the comparison circuit employed for this purpose. Most importantly, the comparison circuit must not draw current from the input voltage source, as this could, among other things, cause damage to the circuit when the voltage is significantly higher than the supply voltage. Further with regard to accuracy, it may be difficult to discern a given voltage threshold that is significantly higher than the reference voltage as the range of voltage threshold that must be detected may exceed the circuit capability in general.
The accuracy of detection is thus dependent upon the comparator circuit or circuitry employed for this purpose. A known technique used to detect a voltage above the supply rail is to use a resistive voltage divider to divide down the input source voltage below the supply rail so that it can be compared to an available reference voltage using a comparator circuit. However, this does not adequately address the problem because the voltage divider will source an undesirable amount of current from the input voltage source, which is not acceptable as discussed.
Another known approach for detecting a voltage above a supply rail is illustrated by FIG. 1. The circuit shown in FIG. 1 is known as a “lopsided” comparator 100, which may be constructed using transistors or field effect transistors (FETs) to form a differential circuit, also referred to as a differential pair, for example using FET 103 and FET 105. The circuit shown in FIG. 1 is therefore also known as a “lopsided” differential pair because, for example FET 105 may be on the order of ten times larger than FET 103.
The lopsided comparator 100 (or lopsided differential pair 100) provides a trip point at voltage high above the reference voltage 101 as required. Because the input FET 103 (which may be, for example, a depletion type n-channel MOSFET) is much smaller than the reference FET 105, the input voltage must be pulled significantly higher than the reference voltage 101 to reach the trip point. The lopsided comparator also includes the two diode-connected FETs 107 and 109 which act as offset voltage circuits to the differential pair formed by FET 103 and FET 105. A current source circuit 111 connected to ground 113 is also present and may be implemented using any appropriate component or circuit.
The lopsided comparator 100 does provide a trip point above the supply voltage 101 with zero input current drain from the input source without the need for a resistive voltage divider. However several accuracy issues exist. A first issue is that the reference voltage 101, being the supply voltage, can vary by as much as ±4% in a typical application. Second, the amount by which the input voltage needs to be pulled higher than the reference voltage 101 to trip the comparator 100 varies significantly over IC fabrication processes and temperature extremes. For example processes such as percentage doping, gate oxide thickness and device geometry variation may adversely effect the trip point. This issue may thus cause yield problems during IC production and testing. Further, “lopsiding” the differential pair forces use of the supply voltage as the reference voltage 101. However in practice a supply voltage is inaccurate and therefore the comparator trip point required may not be achieved due to variations which may be as small as tenths of a volt.